{$CLEO .cs}
{$USE cleo+}
0000:

Model.Load(#STRETCH)
Model.Load(#STALLION)
Model.Load(#STAFFORD)
Model.Load(#WMYSGRD) 
Model.Load(#COLT45) 
038B: load_requested_models
04ED: load_animation  "gangs"

:RESPAWN 

while true 
wait 0
   if   and
   model.Available(#STRETCH)
   model.Available(#STALLION)
   model.Available(#STAFFORD) 
   model.Available(#COLT45)
   model.Available(#WMYSGRD)
   00FE:    actor $PLAYER_ACTOR sphere 0 in_sphere  4801.1904 -2038.4037 11.6027 radius 130.0 130.0 130.0

   then
       break
   end
   if $onmission == 0 
   then
       jump @end
   end
end 

1@=actor.Create(6, #WMYSGRD ,4801.7261, -2105.9167, 11.6027)
2@=actor.Create(6, #WMYSGRD , 4816.4785, -2106.2991, 11.6027)
3@=actor.Create(6, #WMYSGRD , 4803.5615, -2077.3853, 11.6027 )
4@=actor.Create(6, #WMYSGRD ,4810.8247, -2077.1821, 11.6027 )
5@=actor.Create(6, #WMYSGRD ,4801.1904, -2038.4037, 11.6027 )
actor.Angle( 1@ ) =  270.1292
actor.Angle( 2@ ) = 102.0348
actor.Angle( 3@ ) =  274.6678
actor.Angle( 4@ ) =  85.8487
actor.Angle( 5@ ) = 179.6723
  
10@=car.Create(#STALLION , 4785.1108, -2123.0098, 10.396 )
car.Angle(10@)=   87.911
car.Health(10@)= 25000
11@=car.Create(#STAFFORD , 4830.8452, -2123.1345, 10.396)
car.Angle(11@)=   87.911
car.Health(11@)= 25000
12@=car.Create(#STRETCH , 4807.9756, -2123.4016, 10.396 )
car.Angle(12@)= 87.911
car.Health(12@)= 25000
0229: set_car 10@ primary_color_to 0 secondary_color_to 0
0229: set_car 11@ primary_color_to 0 secondary_color_to 0
//0229: set_car 12@ primary_color_to 0 secondary_color_to 0

actor.Health(1@)=500
actor.Health(2@)=500
actor.Health(3@)=500
actor.Health(4@)=500
actor.Health(5@)=500
0638: AS_actor 1@ stay_put 1
0638: AS_actor 2@ stay_put 1
0638: AS_actor 3@ stay_put 1
0638: AS_actor 4@ stay_put 1
0638: AS_actor 5@ stay_put 1

0446: set_actor 1@ dismemberment_possible 0
0446: set_actor 2@ dismemberment_possible 0
0446: set_actor 3@ dismemberment_possible 0
0446: set_actor 4@ dismemberment_possible 0
0446: set_actor 5@ dismemberment_possible 0
07DD: set_actor 1@ attack_rate 80 // previously known as temper_to
07DD: set_actor 2@ attack_rate 80 // previously known as temper_to
07DD: set_actor 3@ attack_rate 80 // previously known as temper_to
07DD: set_actor 4@ attack_rate 80 // previously known as temper_to
07DD: set_actor 5@ attack_rate 80 // previously known as temper_to 
07FE: set_actor 1@ fighting_style_to 15 moves 6
07FE: set_actor 2@ fighting_style_to 5 moves 6
07FE: set_actor 3@ fighting_style_to 7 moves 6
07FE: set_actor 4@ fighting_style_to 5 moves 6
07FE: set_actor 5@ fighting_style_to 15 moves 6

actor.WeaponAccuracy(1@ ) = 40
actor.WeaponAccuracy(2@ ) = 40
actor.WeaponAccuracy(3@ ) = 40
actor.WeaponAccuracy(4@ ) = 40
actor.WeaponAccuracy(5@ ) = 40
07DD: set_actor 1@ attack_rate 60 // previously known as temper_to
07DD: set_actor 2@ attack_rate 60 // previously known as temper_to
07DD: set_actor 3@ attack_rate 60 // previously known as temper_to
 
                actor.GiveWeaponAndAmmo(1@,pistol,99999)
                actor.GiveWeaponAndAmmo(2@,pistol,99999)
                actor.GiveWeaponAndAmmo(3@,pistol,99999)
                actor.GiveWeaponAndAmmo(4@,pistol,99999)
                actor.GiveWeaponAndAmmo(5@,pistol,99999)    
while true 
wait 0
  
  {
    0AE1: 30@  = random_char_near_point  3759.0054 -3485.2244 10.0837 in_radius 99999999999.0 find_next 1 pass_deads 1
   if and
   32@ > 2000
   
   056D:   actor 30@ defined
   then
        if and
        803B: not    30@ == 1@  // (int)
        803B: not    30@ == 2@  // (int)
        803B: not    30@ == 3@  // (int)
        803B: not    30@ == 4@  // (int)
        803B: not    30@ == 5@  // (int) 
        then
           if  and
           056E:   car 10@ defined
           056E:   car 11@ defined
           056E:   car 12@ defined
           then
               if or 
               051C:   car 10@ damaged_by_actor 30@
               051C:   car 11@ damaged_by_actor 30@
               051C:   car 12@ damaged_by_actor 30@
               then
               32@=0 
                actor.GiveWeaponAndAmmo(1@,pistol,99999)
                actor.GiveWeaponAndAmmo(2@,pistol,99999)
                actor.GiveWeaponAndAmmo(3@,pistol,99999)
                actor.GiveWeaponAndAmmo(4@,pistol,99999)
                actor.GiveWeaponAndAmmo(5@,pistol,99999)               
                    054F: clear_car 10@ damage
                    054F: clear_car 11@ damage
                    054F: clear_car 12@ damage
                    05E2: AS_actor 10@ kill_actor 30@
                    05E2: AS_actor 11@ kill_actor 30@
                    05E2: AS_actor 12@ kill_actor 30@

               end
           end 
        end         
   end      }
   if  or 
    $onmission == 0
   80FE: not  actor $PLAYER_ACTOR sphere 0 in_sphere  4801.1904 -2038.4037 11.6027  radius 130.0 130.0 130.0

   then
       break
   end
end 



:CLEANUP
actor.DestroyInstantly(1@)
actor.DestroyInstantly(2@)
actor.DestroyInstantly(3@)
actor.DestroyInstantly(4@)
actor.DestroyInstantly(5@)
car.RemoveReferences(10@)
car.RemoveReferences(11@)
car.RemoveReferences(12@)
if    $onmission == 0
then
   jump @end
else 
   jump @RESPAWN 
end

:end
04EF: release_animation "gangs" 

end_thread